﻿using System.ComponentModel.DataAnnotations;
using System.Web.Mvc;
using Sharp.Portal.AdminLTE;
using Sharp.Portal.Mvc;
using Sharp.Portal.Mvc.Form;

namespace Sharp.WebBooter.Areas.Demo.Models
{
    /// <summary>
    /// 验收
    /// </summary>
    public partial class TroubleshootingModel
    {
        public class AcceptanceInfo : ISharpForm
        {
            public AcceptanceInfo()
            {
                UI = new BSSharpFrom(this);
            }
            [HiddenInput]
            public int Id { get; set; }
            /// <summary>
            /// 验收人
            /// </summary>
            [Display(Name = "验收人"), CustomField(FieldType.SelectBox, "/Platform/Employee/EmployeeDialog/", DisplayField = "", ValueField = nameof(AcceptorId)), Required]
            public string Acceptor { get; set; }
            public int AcceptorId { get; set; }

            /// <summary>
            /// 验收意见
            /// </summary>
            [Display(Name = "验收意见"), DataType(DataType.MultilineText), Required]
            public string AcceptanceOpinion { get; set; }

            /// <summary>
            /// 验收时间
            /// </summary>
            [Display(Name = "验收时间"), DataType(DataType.Date), Required]
            public string AcceptanceTime { get; set; }

            /// <summary>
            /// 上级
            /// </summary>
            [Display(Name = "上级"), CustomField(FieldType.SelectBox, "/Platform/Employee/EmployeeDialog/", DisplayField = "", ValueField = nameof(SuperiorId)), Required]
            public string Superior { get; set; }
            public int SuperiorId { get; set; }
            /// <summary>
            /// 考核
            /// </summary>
            [Display(Name = "考核"), DataType(DataType.MultilineText)]
            public string Assessment { get; set; }

            public SharpFrom UI { get; set; }
        }
    }
}